//引入代码
var call = require('../../util/request.js');

Page({
  data: {
    background: ["demo-text-1", "demo-text-2", "demo-text-3"],
    indicatorDots: true,
    vertical: false,
    autoplay: false,
    interval: 2000,
    duration: 500
  },
  
  onShow(){
	  //商户信息
	  call.getData('api/getMchInfo', this.message, this.fail);
  },
  
  message:function(data){
  	var that = this;
  	that.setData({
  		mess: data.data
  	})
  },
  
  changeIndicatorDots: function(e) {
    this.setData({
      indicatorDots: !this.data.indicatorDots
    });
  },
  changeAutoplay: function(e) {
    this.setData({
      autoplay: !this.data.autoplay
    });
  },
  intervalChange: function(e) {
    this.setData({
      interval: e.detail.value
    });
  },
  durationChange: function(e) {
    this.setData({
      duration: e.detail.value
    });
  }
});